package com.itfreer.gis.entity;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;

import org.springframework.beans.BeanUtils;
import com.itfreer.form.api.JdbcBaseEntity;

/**
 * 定义离线底图实体
 */
@Entity(name = "gis_base_map")
public class JdbcGisBaseMapEntity implements JdbcBaseEntity<GisBaseMapEntity>, Serializable {

	/**
	 * 
	 */
	private static final long serialVersionUID = -3918941515366533366L;

	/**
	 * 主健
	 */
	@Id
	@Column(name = "s_iD", length = 50, nullable = true)
	private String id;

	/**
	 * 数据名称
	 */
	@Column(name = "s_name", length = 50, nullable = true)
	private String name;

	/**
	 * 大小
	 */
	@Column(name = "d_size", nullable = true)
	private Double size;

	/**
	 * 所属区域
	 */
	@Column(name = "s_area", length = 50, nullable = true)
	private String area;

	/**
	 * 是否有效
	 */
	@Column(name = "b_valid", nullable = true)
	private Boolean valid;

	/**
	 * 文件路径
	 */
	@Column(name = "s_path", length = 200, nullable = true)
	private String path;

	/**
	 * 主健
	 */
	public String getId() {
		return id;
	}

	/**
	 * 主健
	 */
	public void setId(String value) {
		this.id = value;
	}

	/**
	 * 数据名称
	 */
	public String getName() {
		return name;
	}

	/**
	 * 数据名称
	 */
	public void setName(String value) {
		this.name = value;
	}

	/**
	 * 大小
	 */
	public Double getSize() {
		return size;
	}

	/**
	 * 大小
	 */
	public void setSize(Double value) {
		this.size = value;
	}

	/**
	 * 所属区域
	 */
	public String getArea() {
		return area;
	}

	/**
	 * 所属区域
	 */
	public void setArea(String value) {
		this.area = value;
	}

	/**
	 * 是否有效
	 */
	public Boolean getValid() {
		return valid;
	}

	/**
	 * 是否有效
	 */
	public void setValid(Boolean value) {
		this.valid = value;
	}

	/**
	 * 文件路径
	 */
	public String getPath() {
		return path;
	}

	/**
	 * 文件路径
	 */
	public void setPath(String value) {
		this.path = value;
	}

	@Override
	public void from(GisBaseMapEntity t) {
		BeanUtils.copyProperties(t, this);
	}

	@Override
	public GisBaseMapEntity toEntity() {
		GisBaseMapEntity toEntity = new GisBaseMapEntity();
		BeanUtils.copyProperties(this, toEntity);
		return toEntity;
	}
}